A declaration of war must be made before any hostile action is taken. You cannot invade other's provinces, blockade their ports, or sink their fleets until you declare war. Lands you conquer always vote with you if you are nominated by the Council for victory.
On the other hand, wars harm your diplomatic relations with other nations who are friendly to the country you attack. The penalties will be greater when you attack countries who have reason to believe you are friendly, such as a signed non-aggression pact.